﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage/MasterMng.master" AutoEventWireup="true" CodeFile="EditExpert.aspx.cs" Inherits="ExpertManager_EditExpert" %>
 <%@ Register assembly="AjaxControlToolkit" 
             namespace="AjaxControlToolkit" tagprefix="asp" %>
<%@ Register assembly="ProudMonkey.Common.Controls"
             namespace="ProudMonkey.Common.Controls" tagprefix="cc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Header1" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
 <div style="background-color:#CCCCFF;direction:rtl;padding-bottom:20px;padding-top:10px;border:1px solid #ccc;box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.075) inset;border-radius: 4px;color:#000066">
        <div style="padding-right:385px; width:100%">
        <asp:Image ID="Image2" runat="server" 
                        ImageUrl="~/Images/ManageUsers.png" Width="17%"  />
        </div>
     
      
        <div style="width:93%;margin:auto;background-color:#CC99FF;border:1px solid #ccc;box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.075) inset;border-radius: 7px;">
       
        <div style="background-color:#9966FF;border-radius: 7px;text-align:center;height:30px">
         <asp:Label ID="Label12" runat="server" Font-Size="14px" ForeColor="#FFFF99" 
                    Text="ویرایش کارشناسان "></asp:Label>
        </div>
          <div >
    <table  style="width: 100%">
       
       
        <tr>
            <td align="center" colspan="3" style="height: 17px">
                <asp:Label ID="Label2" runat="server" 
                    Text="لطفا یکی از حالت های جستجو را انتخاب کنید" Width="100%"></asp:Label>
            </td>
        </tr>
        <tr>
            <td align="center" colspan="3">
                <asp:RadioButtonList ID="RadioButtonList1" runat="server" 
                    RepeatDirection="Horizontal" Width="70%" 
                    onselectedindexchanged="RadioButtonList1_SelectedIndexChanged">
                    <asp:ListItem Value="Name">نام</asp:ListItem>
                    <asp:ListItem Value="LastName">نام خانوادگی</asp:ListItem>
                    <asp:ListItem Value="NatioCode">کد ملی </asp:ListItem>
                    <asp:ListItem Value="Mobile">شماره موبایل</asp:ListItem>
                    
                    
                </asp:RadioButtonList>
                <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                    ConnectionString="<%$ ConnectionStrings:CON %>"  
                    ProviderName="System.Data.SqlClient" 
                    SelectCommand="SELECT [ProvinceName], [ID] FROM [TblProvince]">
                </asp:SqlDataSource>
                
                </td>
        </tr>
        <tr>
            <td align="center" style="height: 6px; width: 502px">
                &nbsp;</td>
            <td align="right" style="height: 6px; width: 502px">
                &nbsp;</td>
            <td>
                &nbsp;</td>
           
        </tr>
        <tr>
            <td align="left" style="height: 6px; width: 502px">
                <asp:TextBox ID="Tser" runat="server" CssClass="textbox"></asp:TextBox>
            </td>
            <td align="right" style="height: 6px; width: 502px">
                <asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="جستجو"  CssClass="Button"/>
            <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                    ControlToValidate="Tser" ErrorMessage="لطفا کلمه مورد نظر را تایپ کنید" 
                    ForeColor="Red"></asp:RequiredFieldValidator>
                <asp:Label ID="LBLStatus" runat="server" BackColor="Yellow" 
                    BorderColor="#003366" ForeColor="#003366"></asp:Label>
            </td>
            <td>
                &nbsp;</td>
           
        </tr>
        <tr>
            <td align="right" style="height: 6px; width: 502px">
                &nbsp;</td>
            <td align="right" style="height: 6px; width: 502px">
                <asp:DropDownList ID="DropDownList1" runat="server" Visible="False">
                </asp:DropDownList>
            </td>
            <td style="height: 6px">
                &nbsp;</td>
        </tr>
        <tr>
            <td align="center" colspan="3">
                <asp:Panel ID="pnlShoData" runat="server" Visible="false">
               
                 <div style="border: 1px solid #DEDEDE;border-radius:3px;box-shadow: 0px 0px 10px rgba(189, 189, 189, 0.4);padding :10px;width:95%;margin:auto;">
                   
                <div  class="headerTable" >
                <div style="width:10%;float:right">
                    <asp:Image ID="Image1" runat="server" src="../Images/ava_default_1.jpg" Height="40px" />
                </div>
                <div style="width:50%;float:right">
                    <h3><asp:Label ID="Label1" runat="server" Text="اطلاعات کاربران ثبت شده"></asp:Label></h3>
                </div>
                
                
                </div>
                <div  >
                <asp:GridView ID="GrdExpert" runat="server" BackColor="White" 
                    BorderColor="#CCCCCC" BorderStyle="None" BorderWidth="1px" CellPadding="3" onrowcommand="GrdExpert_RowCommand" 
                    onrowediting="GrdExpert_RowEditing" AutoGenerateColumns="False" 
                   >
                    <Columns>
                        <asp:BoundField DataField="Name" HeaderText="نام کارشناس" />
                        <asp:BoundField DataField="Family" HeaderText="نام خانوادگی" />
                        <asp:BoundField DataField="Address" HeaderText="آدرس" />
                        <asp:BoundField DataField="Mobile" HeaderText="شماره موبایل" />
                        <asp:BoundField DataField="Telephone" HeaderText="شماره تلفن" />
                        <asp:BoundField DataField="EmailAddress" HeaderText="آدرس ایمیل" />
                        <asp:BoundField DataField="ID" HeaderText="کد کارشناس" />
                        <asp:BoundField DataField="ProvinceName" HeaderText="شهرستان" />
                        <asp:BoundField DataField="ProvinceId" HeaderText="کد شهرستان" />
                        <asp:BoundField DataField="UserName" HeaderText="نام کاربری" />
                        <asp:ButtonField CommandName="RstPass" Text="تغییر رمز عبور" />
                        <asp:ButtonField CommandName="Edit" Text="ویرایش" ImageUrl="../ImageIcon/Edit-icon.png" />
                        <asp:TemplateField>
                        <ItemTemplate>
                            <asp:Button ID="BtnChg" runat="server" Text="غیر فعال"  CommandName="Del"  CommandArgument="<%# ((GridViewRow) Container).RowIndex %>"
                            OnClientClick="ShowConfirmBox(this,'آیا از غیر فعال کردن کارشناس مطمینید'); return false;" CssClass="Button"  />
                          
                        </ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                    <FooterStyle BackColor="White" ForeColor="#000066" />
                    <HeaderStyle BackColor="#006699" Font-Bold="True" ForeColor="White" />
                    <PagerStyle BackColor="White" ForeColor="#000066" HorizontalAlign="Left" />
                    <RowStyle ForeColor="#000066" />
                    <SelectedRowStyle BackColor="#669999" Font-Bold="True" ForeColor="White" />
                    <SortedAscendingCellStyle BackColor="#F1F1F1" />
                    <SortedAscendingHeaderStyle BackColor="#007DBB" />
                    <SortedDescendingCellStyle BackColor="#CAC9C9" />
                    <SortedDescendingHeaderStyle BackColor="#00547E" />
                </asp:GridView>
                </div>
                </div>
                 </asp:Panel>
             </td>
           </tr>
        <tr>
            <td align="center">
               
                &nbsp;</td>
            <td align="center" colspan="2">
               
                <asp:Label ID="Lblsta1" runat="server" BackColor="#FF3300" BorderColor="Yellow" 
                    ForeColor="Yellow"></asp:Label>
             </td>
             <tr>
           
            
            <td >
                <br />
                                <asp:Panel ID="PnlEditExpert" runat="server" Height="79px" Visible="False">
                    <table style="width: 274%; height: 155px;">
                        <tr>
                            <td align="right" style="width: 77px">
                                <asp:Label ID="Label18" runat="server" Text="نام"></asp:Label>
                            </td>
                            <td style="width: 238px">
                                <asp:TextBox ID="Txname" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                            <td style="width: 90px">
                                <asp:Label ID="Label8" runat="server" Text="شماره موبایل"></asp:Label>
                            </td>
                            <td>
                                <asp:TextBox ID="TxMobil" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td align="right" style="width: 77px; height: 30px">
                                <asp:Label ID="Label4" runat="server" Text="نام خانوادگی"></asp:Label>
                            </td>
                            <td style="width: 238px; height: 30px">
                                <asp:TextBox ID="TxFAmily" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                            <td style="width: 90px; height: 30px">
                                <asp:Label ID="Label9" runat="server" Text="کد ملی"></asp:Label>
                            </td>
                            <td style="height: 30px">
                                <asp:TextBox ID="TxNatio" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td align="right" style="height: 31px; width: 77px">
                                <asp:Label ID="Label5" runat="server" Text="آدرس"></asp:Label>
                            </td>
                            <td style="height: 31px; width: 238px">
                                <asp:TextBox ID="Txaddre" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                            <td style="width: 90px; height: 31px">
                                <asp:Label ID="Label10" runat="server" Text="شهرستان"></asp:Label>
                            </td>
                            <td style="height: 31px">
                                <asp:DropDownList ID="Drpro" runat="server" CssClass="textbox" 
                                    DataSourceID="SqlDataSource1" DataTextField="ProvinceName" DataValueField="ID">
                                </asp:DropDownList>
                            </td>
                        </tr>
                        <tr>
                            <td align="right" style="width: 77px">
                                <asp:Label ID="Label6" runat="server" Text="آدرس ایمیل"></asp:Label>
                            </td>
                            <td style="width: 238px">
                                <asp:TextBox ID="Txemail" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                            <td style="width: 90px">
                                &nbsp;</td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td align="right" style="width: 77px">
                                <asp:Label ID="Label7" runat="server" Text="شماره تلفن"></asp:Label>
                            </td>
                            <td style="width: 238px">
                                <asp:TextBox ID="Txtele" runat="server" CssClass="textbox" Font-Size="Medium" 
                                    Width="166px"></asp:TextBox>
                            </td>
                            <td style="width: 90px">
                                <asp:Button ID="Button2" runat="server" CssClass="Button" 
                                    onclick="Button2_Click" Text="انصراف" />
                            </td>
                            <td>
                                <asp:Button ID="BtnEdit" runat="server" CssClass="Button" 
                                    onclick="BtnEdit_Click" Text="ثبت ویرایش" />
                                <asp:Label ID="LblSuccess" runat="server" BackColor="#3399FF" 
                                    BorderColor="Yellow" ForeColor="#FFFF66"></asp:Label>
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
                <br />
                <br />
                <br />
                <br />
                <br />
                <br />
                <br />
                <br />
            </td>
        </tr>
           </tr>
        </table>
                   
    <asp:Panel ID="PnlResetPass" runat="server" Visible="False">
    <table style="width: 100%" >
        <tr>
            <td align="center" bgcolor="#9966FF" colspan="7">
                <asp:Label ID="Label11" runat="server" Font-Size="14px" ForeColor="#FFFF99" 
                    Text="تغییر رمز عبور کارشناسان"></asp:Label>
            </td>
        </tr>
        <tr>
            <td style="width: 194px">
                &nbsp;</td>
            <td style="width: 63px">
                &nbsp;</td>
            <td style="width: 14px">
                &nbsp;</td>
            <td style="width: 118px">
                &nbsp;</td>
            <td align="center" colspan="2">
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td style="width: 194px">
                <asp:Label ID="Label19" runat="server" Text="نام کاربری"></asp:Label>
            </td>
            <td style="width: 63px">
                <asp:TextBox ID="TxUserName" runat="server" CssClass="textbox"></asp:TextBox>
            </td>
            <td align="right" style="width: 14px">
                &nbsp;</td>
            <td style="width: 118px" align="right">
                &nbsp;</td>
            <td align="right" style="width: 170px">
                &nbsp;</td>
            <td style="width: 81px">
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td style="width: 194px; height: 9px;">
                </td>
            <td style="width: 63px; height: 9px;">
                </td>
            <td style="width: 14px; height: 9px;">
                </td>
            <td style="width: 118px; height: 9px;">
                </td>
            <td align="right" style="width: 170px; height: 9px;">
            </td>
            <td style="width: 81px; height: 9px;">
                </td>
            <td style="height: 9px">
                </td>
        </tr>
        <tr>
            <td style="height: 9px; width: 194px">
                </td>
            <td style="height: 9px; width: 63px">
                </td>
            <td style="height: 9px; width: 14px">
                </td>
            <td style="height: 9px; width: 118px">
                </td>
            <td align="right" style="height: 9px; width: 170px">
            </td>
            <td align="left" style="height: 9px; width: 81px">
            </td>
            <td style="height: 9px">
                </td>
        </tr>
        <tr>
            <td style="height: 17px; width: 194px">
                &nbsp;</td>
            <td style="height: 17px; width: 63px">
                &nbsp;</td>
            <td style="height: 17px; width: 14px">
                &nbsp;</td>
            <td style="height: 17px; width: 118px">
                &nbsp;</td>
            <td align="right" style="height: 17px; width: 170px">
                &nbsp;</td>
            <td align="left" style="height: 17px; width: 81px">
            </td>
            <td style="height: 17px">
                &nbsp;</td>
        </tr>
        <tr>
            <td style="height: 17px; width: 194px">
                <asp:Label ID="Label20" runat="server" Text="کلمه عبور جدید"></asp:Label>
            </td>
            <td style="height: 17px; width: 63px">
                <asp:TextBox ID="Txpass" runat="server" CssClass="textbox" TextMode="Password"></asp:TextBox>
            </td>
            <td align="right" style="height: 17px; width: 14px">
                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                    ControlToValidate="Txpass" ErrorMessage="*" ForeColor="Red"></asp:RequiredFieldValidator>
            </td>
            <td align="right" style="height: 17px; width: 118px">
                <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" 
                    ControlToValidate="Txpass" ErrorMessage="حداقل 6 کاراکتر واردکنید" 
                    ForeColor="Red" ValidationExpression=".{6,}"></asp:RegularExpressionValidator>
            </td>
            <td align="right" style="height: 17px; width: 170px">
                &nbsp;</td>
            <td align="left" style="height: 17px; width: 81px">
                &nbsp;</td>
            <td style="height: 17px">
                &nbsp;</td>
        </tr>
        <tr>
            <td style="height: 17px; width: 194px">
                <asp:Label ID="Label21" runat="server" Text="تکرار رمز"></asp:Label>
            </td>
            <td style="height: 17px; width: 63px">
                <asp:TextBox ID="TxConf" runat="server" CssClass="textbox" TextMode="Password"></asp:TextBox>
            </td>
            <td align="right" style="height: 17px; width: 14px">
                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                    ControlToValidate="TxConf" ErrorMessage="*" ForeColor="Red"></asp:RequiredFieldValidator>
            </td>
            <td align="right" style="height: 17px; width: 118px">
                <asp:CompareValidator ID="CompareValidator1" runat="server" 
                    ControlToCompare="Txpass" ControlToValidate="TxConf" 
                    ErrorMessage="تکرار رمز اشتباه است" ForeColor="Red"></asp:CompareValidator>
            </td>
            <td align="right" style="height: 17px; width: 170px">
                &nbsp;</td>
            <td align="left" style="height: 17px; width: 81px">
                &nbsp;</td>
            <td style="height: 17px">
                &nbsp;</td>
        </tr>
        <tr>
            <td style="height: 17px; width: 194px">
                &nbsp;</td>
            <td style="height: 17px; width: 63px">
                &nbsp;</td>
            <td align="right" style="height: 17px; width: 14px">
                &nbsp;</td>
            <td style="height: 17px; width: 118px">
                <asp:Button ID="BtnChgPass0" runat="server" CssClass="Button" Height="27px" 
                    onclick="BtnChgPass_Click" Text="تغییر رمز" />
            </td>
            <td align="right" style="height: 17px; width: 170px">
                &nbsp;</td>
            <td align="left" style="height: 17px; width: 81px">
                &nbsp;</td>
            <td style="height: 17px">
                &nbsp;</td>
        </tr>
        <tr>
            <td style="height: 17px; width: 194px">
                &nbsp;</td>
            <td style="height: 17px; width: 63px">
                &nbsp;</td>
            <td align="right" style="height: 17px; width: 14px">
                &nbsp;</td>
            <td align="right" colspan="2" style="height: 17px; ">
                <asp:Label ID="lblsuccess2" runat="server" BackColor="#CC6699" 
                    BorderColor="Yellow" ForeColor="Yellow"></asp:Label>
            </td>
            <td align="left" style="height: 17px; width: 81px">
                &nbsp;</td>
            <td style="height: 17px">
                &nbsp;</td>
        </tr>
    </table>
    </asp:Panel>
    </div>
    </div>
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="Header" Runat="Server">
</asp:Content>

